package com.xdf.xzymanagementsystem.enums;

/**
 * @author chanchaw
 * @create 2022-12-17 16:05
 */
public enum BillCodeResetEnum {
    DAY("每天重置"),
    MONTH("每月重置"),
    YEAR("每年重置"),
    NEVER("从不重置")
    ;
    private String field;

    public String getField() {
        return field;
    }

    BillCodeResetEnum(String field) {
        this.field = field;
    }

    public static BillCodeResetEnum get(String name) {
        if (name == null || name.length() <= 0) return null;
        for (BillCodeResetEnum e : values()) {
            if (e.getField().equals(name)) return e;
        }
        return null;
    }
}
